#include<iostream>
using namespace std;
	char s[50]=" l like,,,.. C++programming!";
int isbd(char c)
{
	if(c==',') 
		return 1;
	if(c=='.') 
		return 1;
	if(c=='!') 
		return 1;
	if(c==',') 
		return 1;
	if(c==' ') 
		return 1;
	if(c=='?') 
		return 1;
	return 0;
	
 } 
 int main()
 {
 	int i=0;
 	while(s[i]!='\0')
 	{
	 while(isbd (s[i])==1&&s[i]!='\0')
		 i++;
 		 int si=i;
 	    	while(isbd (s[i])==0&&s[i]!='\0')
		    i++;
			int ei=i-1;
 			for(int j=si;j<=ei;j++)
 			{
 				cout<<s[j];
 			
		    }	cout<<endl;
	}  
 }
